package www.reagnetbox.com.adapter;

import android.content.Context;


import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;

import java.util.List;

import www.reagnetbox.com.R;
import www.reagnetbox.com.bean.IdName;

public class TestAdapter extends BaseQuickAdapter<IdName, BaseViewHolder> {
    private BaseViewHolder viewHolder;
    private Context context;

    public TestAdapter(Context context, int resContentView, List<IdName> data) {
        super(resContentView, data);
        this.context = context;
    }

    @Override
    protected void convert(BaseViewHolder viewHolder, IdName item) {
        this.viewHolder = viewHolder;
        viewHolder.setText(R.id.tv_name, item.getName())
                .setText(R.id.tv_name, item.getName())
                .addOnClickListener(R.id.iv_icon);
    }
}

